<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>TMapLoader Demo</title>
</head>

<body>
    <h1>天地图加载器示例</h1>
    <div id="mapContainer" style="width: 800px; height: 600px;"></div>

    <!-- 引入打包后的插件 -->
    <script src="../dist/index.js"></script>

    <!-- 示例代码 -->
    <script>
        console.log(TMapLoader, 'TMapLoader')

        TMapLoader.load({
            key: '您的密钥',
        }).then(T => {
            console.log('地图加载成功:', T)

            const map = new T.Map('mapContainer')

            map.centerAndZoom(new T.LngLat(116.40769, 39.89945), 12)
        }).catch((error) => {
            console.error('地图加载失败:', error)
        })
    </script>
</body>

</html>